let a = [1, 2, 3, 4, 5, 6, 7, 8];
let b = [...a];
console.log(b.splice(4)); // [5,6,7,8]
console.log(b); // [1,2,3,4]
let c = [...a];
console.log(c.splice(4, 2)); // [5,6]
console.log(c); // [1,2,3,4,7,8]
let d = [...a];
console.log(d.splice(4, 2, 10, ["x", "y"], 11)); // [5,6]
console.log(d); // [1,2,3,4,10,['x','y'],11,7,8]
